package com.mj.haier.calc.domain;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import org.hibernate.annotations.Cache;
import org.hibernate.annotations.CacheConcurrencyStrategy;

import javax.persistence.*;

import org.springframework.data.elasticsearch.annotations.Document;
import java.io.Serializable;
import java.util.Objects;

/**
 * The carsInfo entity.
 * @author ycm
 */
@ApiModel(description = "The carsInfo entity. @author ycm")
@Entity
@Table(name = "t_cars_info")
// @Cache(usage = CacheConcurrencyStrategy.NONSTRICT_READ_WRITE)
@Document(indexName = "carsinfo")
public class CarsInfo implements Serializable {

    private static final long serialVersionUID = 1L;

    // @Id
    // @GeneratedValue(strategy = GenerationType.IDENTITY)
    // private Long id;

    /**
     * 车辆管理编号:自定义UUID函数
     */
    @ApiModelProperty(value = "车辆管理编号:自定义UUID函数")
    @Id
    @org.springframework.data.annotation.Id
    @Column(name = "cars_id")
    private String carsId;

    /**
     * 车牌号鲁B12345
     */
    @ApiModelProperty(value = "车牌号鲁B12345")
    @Column(name = "cars_number")
    private String carsNumber;

    /**
     * 司机id
     */
    @ApiModelProperty(value = "司机id")
    @Column(name = "driver_id")
    private String driverId;

    /**
     * 手机号
     */
    @ApiModelProperty(value = "手机号")
    @Column(name = "driver_tel")
    private String driverTel;

    /**
     * 手填身份证号
     */
    @ApiModelProperty(value = "手填身份证号")
    @Column(name = "idcard")
    private String idcard;

    /**
     * 手填行驶证
     */
    @ApiModelProperty(value = "手填行驶证")
    @Column(name = "driving_card")
    private String drivingCard;

    /**
     * 车辆分成比例
     */
    @ApiModelProperty(value = "车辆分成比例")
    @Column(name = "cars_percent")
    private Integer carsPercent;

    /**
     * 车队分成比例
     */
    @ApiModelProperty(value = "车队分成比例")
    @Column(name = "cars_team_percent")
    private Integer carsTeamPercent;

    /**
     * 有效性:0:无效,1:有效
     */
    @ApiModelProperty(value = "有效性:0:无效,1:有效")
    @Column(name = "validate_flag")
    private String validateFlag;

    /**
     * 所属车队
     */
    @ApiModelProperty(value = "所属车队")
    @Column(name = "cars_team_id")
    private String carsTeamId;

    /**
     * 快捷通商户号
     */
    @ApiModelProperty(value = "快捷通商户号")
    @Column(name = "kjt_member_id")
    private String kjtMemberId;

    /**
     * 快捷通账号
     */
    @ApiModelProperty(value = "快捷通账号")
    @Column(name = "kjt_account")
    private String kjtAccount;

    /**
     * 快捷通账户用户名
     */
    @ApiModelProperty(value = "快捷通账户用户名")
    @Column(name = "kjt_user_name")
    private String kjtUserName;

    /**
     * 行政区划代码
     */
    @ApiModelProperty(value = "行政区划代码")
    @Column(name = "ad_code")
    private String adCode;

    // jhipster-needle-entity-add-field - JHipster will add fields here, do not remove
    public String getCarsId() {
        return carsId;
    }

    public CarsInfo carsId(String carsId) {
        this.carsId = carsId;
        return this;
    }

    public void setCarsId(String carsId) {
        this.carsId = carsId;
    }

    public String getCarsNumber() {
        return carsNumber;
    }

    public CarsInfo carsNumber(String carsNumber) {
        this.carsNumber = carsNumber;
        return this;
    }

    public void setCarsNumber(String carsNumber) {
        this.carsNumber = carsNumber;
    }

    public String getDriverId() {
        return driverId;
    }

    public CarsInfo driverId(String driverId) {
        this.driverId = driverId;
        return this;
    }

    public void setDriverId(String driverId) {
        this.driverId = driverId;
    }

    public String getDriverTel() {
        return driverTel;
    }

    public CarsInfo driverTel(String driverTel) {
        this.driverTel = driverTel;
        return this;
    }

    public void setDriverTel(String driverTel) {
        this.driverTel = driverTel;
    }

    public String getIdcard() {
        return idcard;
    }

    public CarsInfo idcard(String idcard) {
        this.idcard = idcard;
        return this;
    }

    public void setIdcard(String idcard) {
        this.idcard = idcard;
    }

    public String getDrivingCard() {
        return drivingCard;
    }

    public CarsInfo drivingCard(String drivingCard) {
        this.drivingCard = drivingCard;
        return this;
    }

    public void setDrivingCard(String drivingCard) {
        this.drivingCard = drivingCard;
    }

    public Integer getCarsPercent() {
        return carsPercent;
    }

    public CarsInfo carsPercent(Integer carsPercent) {
        this.carsPercent = carsPercent;
        return this;
    }

    public void setCarsPercent(Integer carsPercent) {
        this.carsPercent = carsPercent;
    }

    public Integer getCarsTeamPercent() {
        return carsTeamPercent;
    }

    public CarsInfo carsTeamPercent(Integer carsTeamPercent) {
        this.carsTeamPercent = carsTeamPercent;
        return this;
    }

    public void setCarsTeamPercent(Integer carsTeamPercent) {
        this.carsTeamPercent = carsTeamPercent;
    }

    public String getValidateFlag() {
        return validateFlag;
    }

    public CarsInfo validateFlag(String validateFlag) {
        this.validateFlag = validateFlag;
        return this;
    }

    public void setValidateFlag(String validateFlag) {
        this.validateFlag = validateFlag;
    }

    public String getCarsTeamId() {
        return carsTeamId;
    }

    public CarsInfo carsTeamId(String carsTeamId) {
        this.carsTeamId = carsTeamId;
        return this;
    }

    public void setCarsTeamId(String carsTeamId) {
        this.carsTeamId = carsTeamId;
    }

    public String getKjtMemberId() {
        return kjtMemberId;
    }

    public CarsInfo kjtMemberId(String kjtMemberId) {
        this.kjtMemberId = kjtMemberId;
        return this;
    }

    public void setKjtMemberId(String kjtMemberId) {
        this.kjtMemberId = kjtMemberId;
    }

    public String getKjtAccount() {
        return kjtAccount;
    }

    public CarsInfo kjtAccount(String kjtAccount) {
        this.kjtAccount = kjtAccount;
        return this;
    }

    public void setKjtAccount(String kjtAccount) {
        this.kjtAccount = kjtAccount;
    }

    public String getKjtUserName() {
        return kjtUserName;
    }

    public CarsInfo kjtUserName(String kjtUserName) {
        this.kjtUserName = kjtUserName;
        return this;
    }

    public void setKjtUserName(String kjtUserName) {
        this.kjtUserName = kjtUserName;
    }

    public String getAdCode() {
        return adCode;
    }

    public CarsInfo adCode(String adCode) {
        this.adCode = adCode;
        return this;
    }

    public void setAdCode(String adCode) {
        this.adCode = adCode;
    }
    // jhipster-needle-entity-add-getters-setters - JHipster will add getters and setters here, do not remove

    @Override
    public boolean equals(Object o) {
        if (this == o) {
            return true;
        }
        if (o == null || getClass() != o.getClass()) {
            return false;
        }
        CarsInfo carsInfo = (CarsInfo) o;
        if (carsInfo.getCarsId() == null || getCarsId() == null) {
            return false;
        }
        return Objects.equals(getCarsId(), carsInfo.getCarsId());
    }

    @Override
    public int hashCode() {
        return Objects.hashCode(getCarsId());
    }

    @Override
    public String toString() {
        return "CarsInfo{" +
            "carsId='" + getCarsId() + "'" +
            ", carsNumber='" + getCarsNumber() + "'" +
            ", driverId='" + getDriverId() + "'" +
            ", driverTel='" + getDriverTel() + "'" +
            ", idcard='" + getIdcard() + "'" +
            ", drivingCard='" + getDrivingCard() + "'" +
            ", carsPercent=" + getCarsPercent() +
            ", carsTeamPercent=" + getCarsTeamPercent() +
            ", validateFlag='" + getValidateFlag() + "'" +
            ", carsTeamId='" + getCarsTeamId() + "'" +
            ", kjtMemberId='" + getKjtMemberId() + "'" +
            ", kjtAccount='" + getKjtAccount() + "'" +
            ", kjtUserName='" + getKjtUserName() + "'" +
            ", adCode='" + getAdCode() + "'" +
            "}";
    }
}
